/*
 * All rights Reserved, Designed By Rylynn
 * @ClassName:  AbstractGraph
 * @Description:
 * @author: rylynn
 * @date:   2021/7/7
 *
 */

package org.etnetwork.core;

import java.util.Collection;
import java.util.List;
import java.util.Map;
import java.util.Optional;

public abstract class AbstractGraph {
    public abstract AbstractGraph addVertex(Vertex vertex);

    public abstract AbstractGraph addEdge(Edge edge);

    public abstract AbstractGraph addVertices(Vertex... vertices);

    public abstract AbstractGraph addEdges(Edge... edges);

    public abstract AbstractGraph deleteVertex(Vertex vertex);

    public abstract AbstractGraph deleteEdge(Edge edge);

    public abstract AbstractGraph deleteEdgeFrom(Long sourceId);

    public abstract AbstractGraph deleteEdgeTo(Long targetId);

    public abstract AbstractGraph deleteVertices(Vertex... vertices);

    public abstract AbstractGraph deleteEdges(Edge... edges);

    public abstract Optional<Vertex> getVertex(Long id);

    public abstract Optional<Vertex> getEdge(Long source, Long target);

    public abstract List<Vertex> getVertices();

    public abstract List<Edge> getEdges();

    public abstract List<Vertex> getVertices(Map<String, Object> properties);

    public abstract List<Edge> getEdges(Map<String, Object> properties);

    public abstract Optional<Vertex> hasVertex(Long vertexId);

    public abstract Optional<Edge> hasEdge(Long sourceId, Long targetId);

    public abstract Integer getEdgesNumber();

    public abstract Integer getVerticesNumber();
}
